]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
messageTray: Do not show low priority notifications
authorFlorian Müllner <fmuellner@gnome.org>
Fri, 18 Jun 2021 21:15:05 +0000 (23:15 +0200)
committerMarge Bot <marge-bot@gnome.org>
Sun, 22 Aug 2021 19:20:37 +0000 (19:20 +0000)
Low priority notifications are meant for information that doesn't require
immediate attention, so it makes sense to not show a banner for them;
they'll still appear in the notification list in the calendar.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/4265

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1893>

js/ui/messageTray.js

index 654bada6b20c0e222c2ba0f05531468ba8c6e059..8a5c262a99406b1450589a86316524e2013eb2be 100644 (file)
@@ -771,6 +771,9 @@ var Source = GObject.registerClass({
         notification.acknowledged = false;
         this.pushNotification(notification);
 
+        if (notification.urgency === Urgency.LOW)
+            return;
+
         if (this.policy.showBanners || notification.urgency == Urgency.CRITICAL)
             this.emit('notification-show', notification);
     }